package com.mixed.db.model;

import java.sql.Timestamp;
import java.util.Date;

import com.mixed.db.MixedDbException;

public class News extends Entity<News> {

	private static final long serialVersionUID = -2740809640854981500L;

	private String name;
	
	private String title;
	
	private String content;
	
	private String photoUrl;
	
	private Integer newsType;
	
	private Integer orderIndex;
	
	private Timestamp createDate;

	public void setName(String name) {
		this.name = name;
	}

	public String getName() {
		return name;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getTitle() {
		return title;
	}

	public void setCreateDate(Date createDate) {
		Timestamp tt = new Timestamp(createDate.getTime());
		this.createDate = tt;
	}

	public Date getCreateDate() {
		return createDate;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getContent() {
		return content;
	}

	public void setNewsType(Integer newsType) {
		this.newsType = newsType;
	}

	public Integer getNewsType() {
		return newsType;
	}

	public void setPhotoUrl(String photoUrl) {
		this.photoUrl = photoUrl;
	}

	public String getPhotoUrl() {
		return photoUrl;
	}

	public void setOrderIndex(Integer orderIndex) {
		this.orderIndex = orderIndex;
	}

	public Integer getOrderIndex() {
		return orderIndex;
	}

	public int delete() throws MixedDbException {
		return 0;
	}

	public News get() throws MixedDbException {
		return null;
	}

	public int insert() throws MixedDbException {
		System.out.println(this.id);
		return 0;
	}

	public int modify() throws MixedDbException {
		return 0;
	}

	public News isExist() throws MixedDbException {
		// TODO Auto-generated method stub
		return null;
	}
	
	
}
